Skip to content

Force opaque paneBackground#82

Merged
lawrencecchen merged 1 commit intomainfrom
hstack-sibling-buttons
Mar 30, 2026
Merged

Force opaque paneBackground#82
lawrencecchen merged 1 commit intomainfrom
hstack-sibling-buttons

Conversation

@lawrencecchen
Copy link
Copy Markdown

@lawrencecchen lawrencecchen commented Mar 30, 2026

Summary by cubic

Make the Tab Bar split-buttons pane background fully opaque to prevent content bleed-through and ensure consistent contrast in all appearances.

Written for commit 47edbc4. Summary will update on new commits.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 30, 2026

Warning

Rate limit exceeded

@lawrencecchen has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 26 minutes and 1 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 26 minutes and 1 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 503ade51-00a5-4fe6-bb35-99acb0b7c92b

📥 Commits

Reviewing files that changed from the base of the PR and between 2f41524 and 47edbc4.

📒 Files selected for processing (1)
  • Sources/Bonsplit/Internal/Views/TabBarView.swift
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch hstack-sibling-buttons

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@lawrencecchen lawrencecchen merged commit 2564166 into main Mar 30, 2026
1 of 2 checks passed
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 1 file

@greptile-apps
Copy link
Copy Markdown

greptile-apps bot commented Mar 30, 2026

Greptile Summary

This PR fixes a split-button backdrop rendering issue in TabBarView by forcing the pane background color to be fully opaque. It also corrects a duplicate let bg declaration that would have caused a Swift compile error.

Key changes:

  • Removes two identical let bg = TabBarColors.paneBackground(for: appearance) lines (duplicate declaration — compile error in Swift)
  • Replaces them with a single let bg = Color(nsColor: TabBarColors.nsColorPaneBackground(for: appearance).withAlphaComponent(1.0)), explicitly stripping any alpha from the resolved color so the backdrop behind the split buttons is always fully opaque
  • Uses the existing nsColorPaneBackground helper (which returns NSColor) to allow the withAlphaComponent(1.0) call before wrapping back into a SwiftUI Color

Confidence Score: 5/5

  • Safe to merge — the change is minimal, focused, and corrects a real compile-breaking bug alongside the intended opacity fix.
  • The PR makes a single-line change that removes a duplicate declaration (compile error) and enforces opacity. No regressions are expected; all remaining concerns are at most P2 style notes.
  • No files require special attention.

Important Files Changed

Filename Overview
Sources/Bonsplit/Internal/Views/TabBarView.swift Replaces a duplicate (compile-breaking) let bg pair with a single opaque-forced color via nsColorPaneBackground(...).withAlphaComponent(1.0), fixing the split-button backdrop rendering.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[TabBarView: showSplitButtons = true] --> B[Compute bg color]
    B --> C[TabBarColors.nsColorPaneBackground\nfor: appearance]
    C --> D{Has custom chromeBackground hex?}
    D -- Yes --> E[NSColor from hex string]
    D -- No --> F[NSColor.textBackgroundColor\nfallback]
    E --> G[.withAlphaComponent 1.0\nForce opaque]
    F --> G
    G --> H[Color nsColor: ...\nSwiftUI Color]
    H --> I[Gradient fade backdrop\nLinearGradient + Rectangle]
    H --> J[Solid fill backdrop\nRectangle.fill bg]
    I --> K[ZStack overlay\nbehind split buttons]
    J --> K
Loading

Reviews (1): Last reviewed commit: "Force paneBackground fully opaque" | Re-trigger Greptile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant